/**
 *
 */
package com.seeyon.apps.thirdapp.constants;

import com.seeyon.ctp.common.AppContext;
import com.seeyon.ctp.util.TextEncoder;


public class Constants {

    public static final String SEEYON_URL=AppContext.getSystemProperty("thirdApp.itm.oaurl");
    public static final String SEEYON_NW_URL=AppContext.getSystemProperty("thirdApp.itm.oaurlnw");

    public static final String SEEYON_SSO_URL =SEEYON_NW_URL  + "/seeyon/login/sso?from=weixin&ticket=@ticket@";

    public static final String SEEYON_GETTOKEN_URL = SEEYON_NW_URL + "/seeyon/rest/token/" + AppContext.getSystemProperty("thirdApp.rest.username") + "/" + TextEncoder.decode(AppContext.getSystemProperty("thirdApp.rest.password")) + "?loginName=@loginName@&userAgentFrom=weixin";

    public static final String SEEYON_MESSAGE_ACCESS_URL = SEEYON_URL + "/seeyon/thirdApp.do?method=message&ticket=@ticket@&url=@url@";

    /**
     * 2022-07-26 王巧明 · 蓝信消息PC穿透单点地址
     */
    public static final String SEEYON_MESSAGE_ACCESS_PCURL = SEEYON_NW_URL + "/seeyon/login/sso?from=thridappsso&ticket=@ticket@&tourl=@url@";

    public static final String SEEYON_PCPENETRATE_CONTROL_URL = SEEYON_URL+"/seeyon/thirdApp.do?method=distribution";

    public static final String SEEYON_MESSAGE_INDEX_URL = "/seeyon/H5/collaboration/messageIndex.html?html=@html@";

    public static final String SEEYON_APP_INDEX = "/seeyon/H5/collaboration/index.html?html=@html@";

    public static final String SEEYON_APP_COLL = "/seeyon/m3/apps/v5/collaboration/html/colAffairs.html";

    public static final String SEEYON_APP_BBS = "/seeyon/m3/apps/v5/bbs/html/bbsIndex.html";

    public static final String SEEYON_APP_BIZ = "/seeyon/m3/apps/v5/biz/html/default.html";

    public static final String SEEYON_APP_BUL = "/seeyon/m3/apps/v5/bulletin/html/bulIndex.html";

    public static final String SEEYON_APP_DOC = "/seeyon/m3/apps/v5/doc/html/docIndex.html";

    public static final String SEEYON_APP_EDOC = "/seeyon/m3/apps/v5/edoc/html/edocList.html";

    public static final String SEEYON_APP_FP = "/seeyon/m3/apps/v5/footprint/html/footPrintIndex.html";

    public static final String SEEYON_APP_QUERY = "/seeyon/m3/apps/v5/formqueryreport/html/index.html";

    public static final String SEEYON_APP_SALARY = "/seeyon/m3/apps/v5/hr/html/hrSalary.html";

    public static final String SEEYON_APP_INQUIRY = "/seeyon/m3/apps/v5/inquiry/html/inquiryIndex.html";

    public static final String SEEYON_APP_MEETING = "/seeyon/m3/apps/v5/meeting/html/meeting_list_pending.html";

    public static final String SEEYON_APP_NEWS = "/seeyon/m3/apps/v5/news/html/newsIndex.html";

    public static final String SEEYON_APP_SHOW = "/seeyon/m3/apps/v5/show/html/showIndex.html";

    public static final String SEEYON_APP_ATTENDANCE = "/seeyon/m3/apps/v5/attendance/html/attendanceIndex.html";

    public static final String SEEYON_APP_ADDRESSBOOK = "/seeyon/m3/apps/v5/addressbook/html/addressbookIndex.html";

    public static final String SEEYON_APP_CALENDAR = "/seeyon/m3/apps/v5/calendar/html/timeArrange.html";

    public static final String SEEYON_APP_COLLECTION = "/seeyon/m3/apps/v5/mycollection/html/mycollectionIndex.html";

    public static final String SEEYON_APP_REPORT = "/seeyon/m3/apps/v5/seeyonreport/html/index.html";

    public static final String SEEYON_APP_TASK = "/seeyon/m3/apps/v5/taskmanage/html/task_index.html";

    public static final String SEEYON_APP_ALLAPP = "/seeyon/H5/wechat/html/allApps.html";

    public static final String SEEYON_APP_PORTAL = "/seeyon/m3/apps/v5/portal/html/portalIndex.htmll";

    public static final String SEEYON_APP_TEMPLETE = "/seeyon/m3/apps/v5/collaboration/html/templateIndex.html?cmphistoryuuid=1531797747125";

    public static final String SEEYON_APP_MOREWORK = "/seeyon/m3/apps/v5/collaboration/html/newCollaboration.html?templateId=5646091056900489450";

    //public static final String SEEYON_APP_PEENDING = "/seeyon/m3/apps/v5/portal/todo/html/todo-list.html?VJoinOpen=VJoin";

    public static final String SEEYON_APP_PEENDINGnew = "/seeyon/m3/apps/v5/portal/todo/html/todo-list.html?weixinFrom=home&VJoinOpen=VJoin";

    public static final String SEEYON_APP_TEMPLETEC = "/seeyon/m3/apps/v5/collaboration/html/newCollaboration.html?templateId=7242829931551343235";


    public static final String SEEYON_APP_TEMPLETEZ = "/seeyon/m3/apps/v5/collaboration/html/newCollaboration.html?templateId=6352753670655852651";

    public static final String LX_URL=AppContext.getSystemProperty("thirdApp.itm.url");
    public static final String LX_AUTHURL=AppContext.getSystemProperty("thirdApp.itm.authurl");
    public static final String OA_URL=AppContext.getSystemProperty("thirdApp.itm.oaurl");

    public static final String LX_APPID_FIRST=AppContext.getSystemProperty("thirdApp.app.appid");
    public static final String LX_APPID_FIRST_MSG=AppContext.getSystemProperty("thirdApp.app.msg.appid");
    public static final String LX_SECRET_FIRST=AppContext.getSystemProperty("thirdApp.app.appsecret");
    public static final String LX_SECRET_FIRST_MSG=AppContext.getSystemProperty("thirdApp.app.msg.appsecret");
    public static final String LX_ORG_ID=AppContext.getSystemProperty("thirdApp.app.orgid");
    public static final String LX_ID_TYPE=AppContext.getSystemProperty("thirdApp.app.idtype");

    //OA
    public static final String OA_TOKEN_URL = SEEYON_NW_URL + "/seeyon/rest/token/" + AppContext.getSystemProperty("thirdApp.rest.username") + "/" + TextEncoder.decode(AppContext.getSystemProperty("thirdApp.rest.password"));
    public static final String OA_LOGINNAME_URL=SEEYON_NW_URL+"/seeyon/rest/orgMember/telephone/@telephone@?token=@token@";

    //PAGE
    public static final String LX_APPTOKEN_URL=LX_URL+"/v1/apptoken/create?grant_type=client_credential&appid="+LX_APPID_FIRST+"&secret="+LX_SECRET_FIRST;
    public static final String LX_APPTOKEN_URL_MSG=LX_URL+"/v1/apptoken/create?grant_type=client_credential&appid="+LX_APPID_FIRST_MSG+"&secret="+LX_SECRET_FIRST_MSG;
    public static final String LX_USERTOKEN_URL=LX_URL+"/v1/usertoken/create?app_token=@app_token@&grant_type=authorization_code&code=@code@";
    public static final String LX_USERINFO_URL=LX_URL+"/v1/users/fetch?app_token=@app_token@&user_token=@user_token@";
    public static final String LX_USERINFOEXT_URL=LX_URL+"/v1/staffs/@staffid@/idfield/employid/fetch?app_token=@app_token@&user_token=@user_token@";
    public static final String LX_AUTHORIZE_URL=LX_AUTHURL+"/oauth2/authorize?appid="+LX_APPID_FIRST+"&response_type=code&scope=basic_userinfor&state=seeyonstate&redirect_uri=@redirect_uri@";

    // MESSAGE
    public static final String LX_MSSAGE_URL=LX_URL+"/v1/messages/create?app_token=@app_token@";
    public static final String LX_MSSMEMBER_URL=LX_URL+"/v1/staffs/id_mapping/fetch?app_token=@app_token@&org_id="+LX_ORG_ID+"&id_type="+LX_ID_TYPE+"&id_value=@id_value@";
    public static final String LX_JSAPI_URL=LX_URL+"/v1/jsapitoken/create?app_token=@app_token@&user_token=@user_token@";

}
